<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<c:set var="ctx" value="<%=request.getContextPath()%>" />
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<title>中国石油非常规气藏动态分析</title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page" />
<link href="${ctx}/basic/css/table.css" rel="stylesheet" />
<link href="${ctx}/basic/css/index.css" rel="stylesheet" />
<link href="${ctx}/basic/css/style.css" rel="stylesheet" />
<link type="text/css" rel="stylesheet"
	href="${ctx}/js/tree/zTreeStyle/zTreeStyle.css" />
<script type="text/javascript" src="${ctx}/basic/js/jquery-1.9.1.min.js"></script>
<script type="text/javascript"
	src="${ctx}/basic/js/jquery.leanModal.min.js"></script>
</head>
<body>
	<div id="main-container" class="form">
		<div id="tree-container" class="left">
			<ul class="ztree" id="xzqtree"></ul>
		</div>
		<div id="#"
			style="width:100%;height:26px;border-bottom: 0px #F1F1F1 solid ;margin-left:-660px;">
			<select name="s1" id="s1" onChange="redirect()" onclick="redirect()">
				<optgroup label="静态数据">
					<c:forEach var="obj" items="${static}">
						<option value="${obj.value}">${obj.name}</option>
					</c:forEach>
					<!-- <option value="choice" selected ="selected">请选择</option> -->
					<%-- <option value="cjkj">空间信息表</option>
                <option value="cjjbxx">基本信息表</option>
                <option value="cjmcxx">煤层信息表</option>
                <option value="cjsjxx">试井信息表</option>
                <option value="cjgbxx">隔板信息表</option>
                <option value="cjdwxf">等温吸附信息表</option>
                <option value="cjzfxx">组分信息表</option>
                <option value="cjscjt">生产静态数据</option> --%>
				</optgroup>
				<optgroup label="动态数据">
					<c:forEach var="obj" items="${dynamic}">
						<option value="${obj.value}" selected="selected">${obj.name}</option>
					</c:forEach>
				</optgroup>
				<optgroup label="统计数据">
					<c:forEach var="obj" items="${tongji}">
						<option value="${obj.value}">${obj.name}</option>
					</c:forEach>
				</optgroup>
				<!-- <option value="cjbbrsctrue">报表日生产表</option>
            <option value="cjbbtjtrue">报表统计表</option> -->
				<!-- <option value="mcyxpz">煤层岩性配置表   </option> -->

			</select>

			<button href="#loginmodal" id="modaltrigger" onclick="colunms()">列筛选</button>
			<div id="loginmodal" style="display:none;">
				<h3>可选的列</h3>
				<form id="loginform" name="loginform" method="post">
					<a href="javascript:void" class="modal_close"></a>
					<div id="condition1"
						style="font-size:13px;text-align:left;height:260px;overflow-y: auto;border:1px solid #9D9F9C;;background-color:white;">
					</div>
					<div class="center">
						<img id="buttonOk2" src="${ctx}/basic/images/btOk2.gif"
							onclick="checktable()" title="提交"> <img id="buttonchoose"
							class="button_q" src="${ctx}/basic/images/btC.jpg"
							onclick="check_all()" title="全选/全不选">
					</div>
				</form>
			</div>
			<script type="text/javascript">
				$('#modaltrigger').leanModal({
					top : 110,
					overlay : 0.45,
					closeButton : ".modal_close"
				});
			</script>

			<button href="#loginmodal1" id="modaltrigger1" onclick="col()">关键字查询</button>
			<div id="loginmodal1" style="display:none;">

				<h3>关键字查询</h3>
				<form id="loginform1" name="loginform1" method="post">
					<a href="javascript:void" class="modal_close"></a>
					<div id="condition2"
						style="font-size:10px;height:100px;overflow-y: auto;border:1px solid #9D9F9C;;background-color:white;">
						<p style="float:left">
							投产日期：<input type="text" name="tiaojian" />
						</p>
						<p style="float:left">
							见气时间：<input type="text" name="tiaojian" />
						</p>
					</div>
					<div class="center">
						<img id="buttonOk2" src="${ctx}/basic/images/btOk2.gif"
							onclick="gsubmit()" title="提交"> <img id="buttonReset1"
							src="${ctx}/basic/images/btReset1.gif" onclick="clearText()"
							title="重置">
					</div>
				</form>
			</div>
			<script type="text/javascript">
				$('#modaltrigger1').leanModal({
					top : 110,
					overlay : 0.45,
					closeButton : ".modal_close"
				});
			</script>

			<button href="#loginmodal2" id="modaltrigger2" style="float:right;"
				onclick="adtiaojian()">高级查询</button>
			<div id="loginmodal2" style="display:none;">
				<h3>可选的条件</h3>
				<form id="loginform2" name="loginform2" method="post">
					<a href="javascript:void" class="modal_close"></a>
					<div id="condition3"
						style="font-size:10px;height:130px;overflow-y: auto;border:1px solid #9D9F9C;;background-color:white;">
						<div style="width: 35px;float: left;margin-left: 5px;height:102px">
							<img width="15px" height="25px" src="${ctx}/basic/images/add.gif"
								title="增" onclick="addRow();this.blur();"> <img
								width="15px" height="25px" src="${ctx}/basic/images/del.gif"
								title="减" onclick="deleteRow();this.blur();">
						</div>
						<div id="au_1" class="au_n" style="width:500px;">
							<select title="选择表" id="s_1" class="sfield"
								onchange="adtiaojian1('s_1','sfield_1')">
								<option value="greeting">选择表</option>
								<c:forEach var="obj" items="${table}">
									<option value="${obj.value}">${obj.name}</option>
								</c:forEach>
							</select> <select title="选择列" id="sfield_1" class="sfield">
								<option value="greeting">选择列</option>
							</select> <select id="operator_1" title="请选择运算符" class="operator">
								<option value="greeting">请选择运算符</option>
								<option value=">">&gt;</option>
								<option value="<">&lt;</option>
								<option value="<=">&lt;=</option>
								<option value=">=">&gt;=</option>
								<option value="=">=</option>
							</select> <input type="text" id="text_1" class="val_text"
								style="display: inline-block;">
						</div>
						<div style="display:none;width:500px;" class="au_n" id="au_2">
							<select title="选择表" id="s_2" class="sfield"
								onchange="adtiaojian1('s_2','sfield_2')">
								<option value="greeting">选择表</option>
								<c:forEach var="obj" items="${table}">
									<option value="${obj.value}">${obj.name}</option>
								</c:forEach>
							</select> <select id="sfield_2" title="选择列" class="sfield">
								<option value="greeting">选择列</option>
							</select> <select id="operator_2" title="请选择运算符" class="operator">
								<option value="greeting">请选择运算符</option>
								<option value=">">&gt;</option>
								<option value="<">&lt;</option>
								<option value="<=">&lt;=</option>
								<option value=">=">&gt;=</option>
								<option value="=">=</option>
							</select> <input type="text" id="text_2" class="val_text"
								style="display: inline-block;">
						</div>
						<div style="display:none;width:500px;" class="au_n" id="au_3">
							<select title="选择表" id="s_3" class="sfield"
								onchange="adtiaojian1('s_3','sfield_3')">
								<option value="greeting">选择表</option>
								<c:forEach var="obj" items="${table}">
									<option value="${obj.value}">${obj.name}</option>
								</c:forEach>
							</select> <select id="sfield_3" title="选择列" class="sfield">
								<option value="greeting">选择列</option>
							</select> <select id="operator_3" title="请选择运算符" class="operator">
								<option value="greeting">请选择运算符</option>
								<option value=">">&gt;</option>
								<option value="<">&lt;</option>
								<option value="<=">&lt;=</option>
								<option value=">=">&gt;=</option>
								<option value="=">=</option>
							</select> <input type="text" id="text_3" class="val_text"
								style="display: inline-block;">
						</div>
						<div style="display:none;width:500px;" class="au_n" id="au_4">
							<select title="选择表" id="s_4" class="sfield"
								onchange="adtiaojian1('s_4','sfield_4')">
								<option value="greeting">选择表</option>
								<c:forEach var="obj" items="${table}">
									<option value="${obj.value}">${obj.name}</option>
								</c:forEach>
							</select> <select id="sfield_4" title="选择列" class="sfield">
								<option value="greeting">选择列</option>
							</select> <select id="operator_4" title="请选择运算符" class="operator">
								<option value="greeting">请选择运算符</option>
								<option value=">">&gt;</option>
								<option value="<">&lt;</option>
								<option value="<=">&lt;=</option>
								<option value=">=">&gt;=</option>
								<option value="=">=</option>
							</select> <input type="text" id="text_4" class="val_text"
								style="display: inline-block;">
						</div>
						<input id="au_i" type="hidden" value="1" name="au_i"> <input
							id="au_c" type="hidden" value="4" name="au_c">
					</div>
					<div class="center">
						<img id="buttonOk2" src="${ctx}/basic/images/btOk2.gif"
							onclick="advance()" title="提交">
						<%-- <img id="buttonReset1"
                                                              src="${ctx}/basic/images/btReset1.gif" onclick="clearText1()"
                                                              title="重置"> --%>
					</div>
				</form>
			</div>
			<script type="text/javascript">
				$('#modaltrigger2').leanModal({
					top : 110,
					overlay : 0.45,
					closeButton : ".modal_close"
				});
			</script>

		</div>
		<div id="tablename">
			<div style="font-size:25px;float:right;margin-right:400px;">排采动态数据表</div>
		</div>
		<div>
			<div style="margin-left:1220px;" onclick="show()">
				<img src="basic/images/xls.gif" />
			</div>
			<span id="daochu" style="display:none;margin-right:60px;float:right;position:relative;">
				<input type="button" id="btn1"
				onclick="exportExcel('1')" value="导出全部"> <input
				type="button" id="btn2" onclick="exportExcel('2')"
				value="导出所选"> </span>
		</div>

		<div id="data_table" class="tablecss">
			<table id="table1">
				<tr bgcolor="#FFEC8B">
					<th name='t0' class='tab_title tabel_hei'><input
						type="checkbox" name="record1" onclick="quanxuan()" />全选</th>
					<th name='t1' class='tab_title tabel_hei'>编码</th>
					<th name='t2' class='tab_title tabel_hei'>生产日期</th>
					<th name='t3' class='tab_title tabel_hei'>月累产气</th>
					<th name='t4' class='tab_title tabel_hei'>年累产气</th>
					<th name='t5' class='tab_title tabel_hei'>累产气量</th>
					<th name='t6' class='tab_title tabel_hei'>月累产液</th>
					<th name='t7' class='tab_title tabel_hei'>年累产液</th>
					<th name='t8' class='tab_title tabel_hei'>累产液量</th>
				</tr>
				<c:forEach var="obj" items="${basic.list}">
					<tr>
						<td name='t0' class='tab_title tabel_hei'><input
							type='checkbox' checked='checked' name='record' value='${obj.ID}'>
						</td>
						<td name='t1' class='tab_title tabel_hei'>${obj.wellname}</td>
						<td name='t2' class='tab_title tabel_hei'>${obj.SCRQ}</td>
						<td name='t3' class='tab_title tabel_hei'>${obj.YLCQ}</td>
						<td name='t4' class='tab_title tabel_hei'>${obj.LLCQ}</td>
						<td name='t5' class='tab_title tabel_hei'>${obj.LJCQ}</td>
						<td name='t6' class='tab_title tabel_hei'>${obj.YLCY}</td>
						<td name='t7' class='tab_title tabel_hei'>${obj.LLCY}</td>
						<td name='t8' class='tab_title tabel_hei'>${obj.LJCY}</td>
					</tr>
				</c:forEach>
			</table>
		</div>
		<div id="paginate" class="mybutton"
			style="font-size:13px;margin-left:0 auto;">
			<span class="pageshow" style="border: none"> 共<label
				id="lblToatl">${basic.totalRow}</label>条数据第[<label id="lblCurent">${basic.pageNumber}</label>]页/共[<label
				id="lblPageCount">${basic.totalPage}</label>]页 </span> <span><a
				id="first" name="first" href="javascript:void(0)">首页</a> </span> <span><a
				id="previous" name="previous" href="javascript:void(0)">上一页</a> </span> <span><a
				id="next" name="next" href="javascript:void(0)">下一页</a> </span> <span><a
				id="last" name="last" href="javascript:void(0)">末页</a> </span>
		</div>
	</div>
	<script type="text/javascript" src="${ctx}/js/jquery.min.js"></script>
	<script type="text/javascript"
		src="${ctx}/js/tree/jquery.ztree.all-3.5.min.js"></script>
	<script type="text/javascript" src="${ctx}/basic/js/base.js"></script>
	<!--EXTjs引入  -->
	<script type="text/javascript" src="${ctx}/js/extjs/ext-all.js"></script>
	<script type="text/javascript"
		src="${ctx}/js/extjs/locale/ext-lang-zh_CN.js"></script>
	<script type="text/javascript" src="${ctx}/basic/js/excel.js"></script>
</body>
</html>
